/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package model;

import java.util.Random;

/**
 *
 * @author Stupi
 */
public class InitRandomPoints {
    
    private static Point [] points;
    
    
  
    public void initializePoints (int numberOfPoints, int panelWidth, int panelHeight) {
        
        
        points = new Point[numberOfPoints];
        
        Random random = new Random();
        
        for (int i = 0; i < points.length; i++) {
            Point point = new Point();
            
            int x = random.nextInt(panelWidth-2)+1;
            int y = random.nextInt(panelHeight-2)+1;
            
            point.setX(x);
            point.setY(y);
            point.setSequenceNumber(i);
            
            points[i] = point;
        }
        
    }

    public static Point[] getPoints() {
        return points;
    }
    
    
    
    
    
}
